﻿#pragma warning(disable: 4996)
#pragma warning(disable: 6031)

/*
*/

#include <stdlib.h>
#include <stdio.h>
#include <string.h>

typedef struct TContext_s
{
	int n;
	int scores[10001];
	double average;
}TContext;

TContext context;

void read_data(TContext* ctx)
{
	scanf("%d", &ctx->n);
	for (int i = 0; i < ctx->n; ++i)
		scanf("%d", &ctx->scores[i]);
	ctx->average = 0;
}

void dump(TContext* ctx)
{
}

void stat(TContext* ctx)
{
	if (ctx->n == 0)
	{
		printf("average = %.1lf\n", ctx->average);
		printf("count = %d\n", 0);
		return 0;
	}
	ctx->average = 0;
	int m = 0;
	for (int i = 0; i <= ctx->n; ++i)
	{
		ctx->average += ctx->scores[i];
		if (ctx->scores[i] >= 60)
			m++;
	}
	ctx->average /= ctx->n;
	printf("average = %.1lf\n", ctx->average);
	printf("count = %d\n", m);
}

void solve(TContext* ctx)
{
	read_data(ctx);
	stat(ctx);
}

int main()
{
	freopen("D:/Develop/GitRepos/MOOC/浙江大学/数据结构/201906/DataStructure/M2019秋C入门和进阶练习集/7-95.txt", "r", stdin);
	solve(&context);
	return 0;
}
